﻿$(function () {
    window.afterShow();
});
window.afterShow = function () {
    if (!parent.resizeAvalibleFrame) return;
    var h = document.body.scrollHeight;
    h = parseInt(h, 10);
    parent.resizeAvalibleFrame(h);
}

window.LoadState = function (arrivalDate, departureDate, apartmentType, peoples) {
    $('#content').hide();
    $('#loader').show();
    window.afterShow();
    $('#arrivalDate').val(arrivalDate);
    $('#departureDate').val(departureDate);
    $('#apartmentType').val(apartmentType);
    $('#peoples').val(peoples);
    $('form').submit();
}